package com.xiaobias.com.xiaobias.order.service;

import com.xiaobias.com.xiaobias.order.mapper.OrderMapper;
import com.xiaobias.com.xiaobias.order.pojo.Order;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class OrderService {

    private final OrderMapper orderMapper;

    @Autowired
    public OrderService(OrderMapper orderMapper) {
        this.orderMapper = orderMapper;
    }

    public Order queryOrderById(Long id) {
        // 1. 查询订单
        // 2. 返回
        return this.orderMapper.findById(id);
    }
}
